<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ page import="java.util.*,com.guolibbs.vo.*" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<link rel="stylesheet" type="text/css" href="css/wltopic.css">
</head>
<body>
<div class="main">
	<div class="head">上海国利</div>
	<div class="nav">
		<a href="${pageContext.request.contextPath }/WlbbsServlet">返回</a>
	</div>
	<div class="content">
		<div class="table">
			<table>
				<tr><td>发帖人</td><td>标题</td><td>内容</td><td>发贴日期</td></tr>
			<% 
				Topic topic = (Topic)request.getAttribute("topic"); 
				if(topic!=null){
			%>
						<tr>
							<td><%=topic.getPoster().getUsername() %></td>
							<td><%=topic.getTopicName()%></td>
							<td><%=topic.getContent()%></td>
							<td><%=topic.getPostTime() %></td>
						</tr>
			<%
					}
			%>
			</table>
			<hr color="navy">
			<table>
				<tr><td>回贴人</td><td>内容</td><td>回贴日期</td></tr>
				<%
					List<Reply> replyList = (List<Reply>)request.getAttribute("replyList");
					if(replyList!=null){
						for(Reply r:replyList){
						%>
							<tr><td><%=r.getReplyName() %></td><td><%=r.getContent() %></td><td><%=r.getReplyTime() %></td></tr>
						<%
						}
					}
				%>
			</table>
		</div>
		<div class="form">
			<form action="${pageContext.request.contextPath }/Wlreply" method="post">
				<input type="hidden" name="topicName" value="<%=topic.getTopicName()%>">
				<textarea rows="5" cols="80" name="reply"></textarea>
				<input type="submit" value="回复">
			</form>
		</div>
	</div>
	<div class="foot">
		@copyright/2012-08/by ShanghaiGuoLi/<span>v1.20</span>
	</div>
</div>
</body>
</html>